/**
 * 
 */
package com.wsj.dao.hibernate;

import java.util.List;

import org.springframework.orm.hibernate3.support.HibernateDaoSupport;

import com.wsj.dao.IBmResearchReportTypeDao;
import com.wsj.util.exception.BusinessException;
import com.wsj.web.vo.homeSite.BmResearchReportType;

/**
 * @author fengbin  createTime:2009-7-25
 * 研究报告类型
 */
public class BmResearchReportTypeDaoImpl extends HibernateDaoSupport implements IBmResearchReportTypeDao {

	/***********
	 * 通过id,获取研究报告类型
	 */
	public BmResearchReportType getBmResearchReportTypeById(int bmResearchReportTypeId) throws BusinessException {
		
		return  (BmResearchReportType) this.getHibernateTemplate().get(BmResearchReportType.class,bmResearchReportTypeId);
		
	}

	/******
	 * 获取研究报告类型列表
	 */
	@SuppressWarnings("unchecked")
	public List<BmResearchReportType> getBmResearchReportTypeList() throws BusinessException {
	    
		return this.getHibernateTemplate().find(" from BmResearchReportType b order by b.id desc");
	}

}
